from flask_restful import Api, Resource
from applications.models.task_model import Task
from applications.schemas.task_schema import TaskSchema


class TaskResource(Resource):
    def get(self):
        tasks = Task.query.all()
        return TaskSchema(many=True).dump(tasks)

